home *** CD-ROM | disk | FTP | other *** search
/ PC Welt 2001 January / PC-WELT 01-2001.ISO / software / linux / office / f_0104 / jvmsetup
Encoding:
Text File  |  2000-10-12  |  3.8 KB  |  128 lines

  1. #!/bin/sh
  2. #*************************************************************************
  3. #
  4. #   $RCSfile: jvmsetup.sh,v $
  5. #
  6. #   $Revision: 1.1.1.1 $
  7. #
  8. #   last change: $Author: hr $ $Date: 2000/09/18 16:51:05 $
  9. #
  10. #   The Contents of this file are made available subject to the terms of
  11. #   either of the following licenses
  12. #
  13. #          - GNU Lesser General Public License Version 2.1
  14. #          - Sun Industry Standards Source License Version 1.1
  15. #
  16. #   Sun Microsystems Inc., October, 2000
  17. #
  18. #   GNU Lesser General Public License Version 2.1
  19. #   =============================================
  20. #   Copyright 2000 by Sun Microsystems, Inc.
  21. #   901 San Antonio Road, Palo Alto, CA 94303, USA
  22. #
  23. #   This library is free software; you can redistribute it and/or
  24. #   modify it under the terms of the GNU Lesser General Public
  25. #   License version 2.1, as published by the Free Software Foundation.
  26. #
  27. #   This library is distributed in the hope that it will be useful,
  28. #   but WITHOUT ANY WARRANTY; without even the implied warranty of
  29. #   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  30. #   Lesser General Public License for more details.
  31. #
  32. #   You should have received a copy of the GNU Lesser General Public
  33. #   License along with this library; if not, write to the Free Software
  34. #   Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  35. #   MA  02111-1307  USA
  36. #
  37. #
  38. #   Sun Industry Standards Source License Version 1.1
  39. #   =================================================
  40. #   The contents of this file are subject to the Sun Industry Standards
  41. #   Source License Version 1.1 (the "License"); You may not use this file
  42. #   except in compliance with the License. You may obtain a copy of the
  43. #   License at http://www.openoffice.org/license.html.
  44. #
  45. #   Software provided under this License is provided on an "AS IS" basis,
  46. #   WITHOUT WARRUNTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING,
  47. #   WITHOUT LIMITATION, WARRUNTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
  48. #   MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
  49. #   See the License for the specific provisions governing your rights and
  50. #   obligations concerning the Software.
  51. #
  52. #   The Initial Developer of the Original Code is: Sun Microsystems, Inc..
  53. #
  54. #   Copyright: 2000 by Sun Microsystems, Inc.
  55. #
  56. #   All Rights Reserved.
  57. #
  58. #   Contributor(s): _______________________________________
  59. #
  60. #
  61. #
  62. #*************************************************************************
  63.  
  64. # resolve installation directory
  65. sd_platform=`uname -s`
  66. case $sd_platform in
  67.     SCO_SV) test=/bin/test     ;;
  68.     *)      test=/usr/bin/test ;;
  69. esac
  70.  
  71. sd_cwd="`pwd`"
  72. if $test -L "$0" ; then
  73.     sd_basename=`basename "$0"`
  74.     sd_script=`ls -l $0 | sed "s/.*${sd_basename} -> //g"`
  75. else
  76.     sd_script="$0"
  77. fi
  78.  
  79. cd "`dirname "$sd_script"`/.."
  80. sd_binary=`basename "$sd_script"`".bin"
  81. sd_inst="`pwd`"
  82.  
  83. # change back directory
  84. cd "$sd_cwd"
  85.  
  86. sd_fonts=$sd_inst/fonts
  87.  
  88. # set search path for shared libraries
  89. case $sd_platform in
  90.   SunOS)
  91.     sd_arch=`uname -p`
  92.     LD_LIBRARY_PATH=$sd_inst/program/service:$sd_inst/program:/usr/openwin/lib:/usr/dt/lib:$LD_LIBRARY_PATH
  93.     export LD_LIBRARY_PATH
  94.     ;;
  95.  
  96.   AIX)
  97.     LIBPATH=$sd_inst/program:$LIBPATH
  98.     export LIBPATH
  99.     ;;
  100.  
  101.   HP-UX)
  102.     SHLIB_PATH=$sd_inst/program:/usr/openwin/lib:$SHLIB_PATH
  103.     export SHLIB_PATH
  104.     ;;
  105.  
  106.   IRIX)
  107.     LD_LIBRARYN32_PATH=:$sd_inst/program:$LD_LIBRARYN32_PATH
  108.     export LD_LIBRARYN32_PATH
  109.     ;;
  110.  
  111.   *)
  112.     LD_LIBRARY_PATH=$sd_inst/program:$LD_LIBRARY_PATH
  113.     export LD_LIBRARY_PATH
  114.     ;;
  115. esac
  116.  
  117. # misc. environment variables
  118. SAL_FONTPATH=$sd_fonts/type1:$sd_fonts/75dpi
  119.  
  120. unset XENVIRONMENT
  121.  
  122. export SAL_FONTPATH
  123.  
  124. # execute soffice binary
  125. # there is a bug in solaris sh that prevents the use of "$@"
  126. # because it cannot cope with spaces in directory names
  127. exec "$sd_inst/program/$sd_binary" "$1" "$2" "$3" "$4" "$5" "$6" "$7" "$8" "$9"
  128.